import {post,get,put,del} from './http.js';

//登录
export const login = param => post('login', param);

//注册
export const register = param => post('auth/register', param);

//测试
export const test = param => get('user/test', param);

//退出账号
export const logout = param => get('logout', param);

//获取用户列表
export const userList = param => get('admin/user/list', param);

//添加用户
export const addUser = param => post('admin/user/add', param);

//修改用户信息
export const setUser = param => put('admin/user/set', param);

//删除用户
export const delUser = param => del('admin/user/del', param);

//获取角色列表
export const roleList = param => get('admin/role/list', param);

//添加角色
export const addRole = param => post('admin/role/add', param);

//修改角色信息
export const setRole = param => put('admin/role/set', param);

//删除角色
export const delRole = param => del('admin/role/del', param);

//获取权限列表
export const permitsList = param => get('admin/permits/list', param);

//添加权限
export const addPermits = param => post('admin/permits/add', param);

//修改权限信息
export const setPermits = param => put('admin/permits/set', param);

//删除权限
export const delPermits = param => del('admin/permits/del', param);

//增加任务面板
export const addTaskType = param => post('task/type/add', param);

//删除任务面板
export const delTaskType = param => del('task/type/del', param);

//获取面板列表
export const taskTypeList = param => get('task/list', param);

//添加任务
export const addTask = param => post('task/add', param);

//修改任务
export const setTask = param => put('task/set', param);

//删除任务
export const delTask = param => del('task/del', param);

//获取任务列表
export const logList = param => get('log/list', param);

//删除日志
export const delLog = param => del('log/del', param);
